package com.wangdao.wechatmall.bean.vo.wx;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * @Description:
 * @Author: JK
 * @Date: create in 2021/7/11 15:16
 */
@AllArgsConstructor
@NoArgsConstructor
@Data
public class HomeIndexVO {

    private List<NewGoodsListDTO> newGoodsList;
    private List<CouponListDTO> couponList;
    private List<ChannelDTO> channel;
    private List<GrouponListDTO> grouponList;
    private List<BannerDTO> banner;
    private List<BrandListDTO> brandList;
    private List<HotGoodsListDTO> hotGoodsList;
    private List<TopicListDTO> topicList;
    private List<FloorGoodsListDTO> floorGoodsList;

    @AllArgsConstructor
    @NoArgsConstructor
    @Data
    public static class NewGoodsListDTO {
        private Integer id;
        private String name;
        private String brief;
        private String picUrl;
        private Boolean isNew;
        private Boolean isHot;
        private BigDecimal counterPrice;
        private BigDecimal retailPrice;
    }

    @AllArgsConstructor
    @NoArgsConstructor
    @Data
    public static class CouponListDTO {
        private Integer id;
        private String name;
        private String desc;
        private String tag;
        private BigDecimal discount;
        private BigDecimal min;
        private Short days;
        private Date startTime;
        private Date endTime;
    }

    @AllArgsConstructor
    @NoArgsConstructor
    @Data
    public static class ChannelDTO {
        private Integer id;
        private String name;
        private String iconUrl;
    }

    @AllArgsConstructor
    @NoArgsConstructor
    @Data
    public static class GrouponListDTO {
        private BigDecimal groupon_price;
        private GoodsDTO goods;
        private Short groupon_member;

        @AllArgsConstructor
        @NoArgsConstructor
        @Data
        public static class GoodsDTO {
            private Integer id;
            private String name;
            private String brief;
            private String picUrl;
            private BigDecimal counterPrice;
            private BigDecimal retailPrice;
        }
    }

    @AllArgsConstructor
    @NoArgsConstructor
    @Data
    public static class BannerDTO {
        private Integer id;
        private String name;
        private String link;
        private String url;
        private Byte position;
        private String content;
        private Boolean enabled;
        private Date addTime;
        private Date updateTime;
        private Boolean deleted;
    }

    @AllArgsConstructor
    @NoArgsConstructor
    @Data
    public static class BrandListDTO {
        private Integer id;
        private String name;
        private String desc;
        private String picUrl;
        private Double floorPrice;
    }

    @AllArgsConstructor
    @NoArgsConstructor
    @Data
    public static class HotGoodsListDTO {
        private Integer id;
        private String name;
        private String brief;
        private String picUrl;
        private Boolean isNew;
        private Boolean isHot;
        private BigDecimal counterPrice;
        private BigDecimal retailPrice;
    }

    @AllArgsConstructor
    @NoArgsConstructor
    @Data
    public static class TopicListDTO {
        private Integer id;
        private String title;
        private String subtitle;
        private BigDecimal price;
        private String readCount;
        private String picUrl;
    }

    @AllArgsConstructor
    @NoArgsConstructor
    @Data
    public static class FloorGoodsListDTO {
        private String name;
        private List<GoodsListDTO> goodsList;
        private Integer id;

        @AllArgsConstructor
        @NoArgsConstructor
        @Data
        public static class GoodsListDTO {
            private Integer id;
            private String name;
            private String brief;
            private String picUrl;
            private Boolean isNew;
            private Boolean isHot;
            private BigDecimal counterPrice;
            private BigDecimal retailPrice;
        }
    }
}
